// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3) 

package com.nnee.p_a.p_b;

import java.io.IOException;
import java.io.OutputStream;
import org.apache.http.util.EncodingUtils;

// Referenced classes of package com.nnee.a.b:
//            d

public class cls_g extends cls_d
{

    public cls_g(String s1, String s2)
    {
        this(s1, s2, null);
    }

    public cls_g(String s1, String s2, String s3)
    {
    	super(s1, "text/plain", s3, "8bit");
    	
        if(s3 == null)
            s3 = "US-ASCII";
        
        if(s2 == null)
            throw new IllegalArgumentException("Value may not be null");
        if(s2.indexOf('\0') != -1)
        {
            throw new IllegalArgumentException("NULs may not be present in string parts");
        } else
        {
            u = s2;
            return;
        }
    }

    private byte[] j()
    {
        if(t == null)
            t = EncodingUtils.getBytes(u, d());
        return t;
    }

    public void a(String s1)
    {
        super.a(s1);
        t = null;
    }

    protected void f(OutputStream outputstream)
    {
        try {
			outputstream.write(j());
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
    }

    protected long h()
    {
        return (long)j().length;
    }

    public static final String q = "text/plain";
    public static final String r = "US-ASCII";
    public static final String s = "8bit";
    private byte t[];
    private String u;
}
